feat: scaffold react-kit with core, ui, next and http modules - #1
Merged
Merged
Conversation
Extracts the code duplicated across gardenia-web and nextjs-template's src/shared/ trees into a publishable library, mirroring the @sisques-labs/nestjs-kit tooling pattern (semantic-release, GitHub Actions CI/release, subpath exports): - core (package root): find-by-criteria domain interfaces/enums, useDebouncedValue, i18n helpers, logHttpError, refreshTokenOnce - /ui: the full shadcn/Radix component catalog (67 components) - /next: route-handler proxy passthrough plus the 5 components that render next/image - /http: dependency-injected axios/Apollo/TanStack Query factories replacing the hand-rolled, app-specific singleton clients, sharing one 401-refresh mutex across both HTTP transports Build via tsc + tsc-alias (preserves 'use client' directives per file), tested with Vitest + RTL at an 80% coverage threshold.
JSisques
commented
Aug 8, 2026
Fast lint-staged on pre-commit, build + changed-tests on pre-push, matching gardenia-web's convention instead of running the full lint+build+test suite on every commit.
|
🎉 This PR is included in version 1.0.0-alpha.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.0.0-beta.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Scaffolds
@sisques-labs/react-kit, a new publishable npm library extracting the code duplicated acrossgardenia-webandnextjs-template'ssrc/shared/trees, modeled on@sisques-labs/nestjs-kit's tooling conventions (semantic-release, GitHub Actions CI/release, subpath exports).core) — find-by-criteria domain interfaces/enums (Filter,Sort,ListCriteria,PaginatedResult,CreatedEntity,FilterOperator,SortDirection),useDebouncedValue, i18n helpers (t,isLocale,WidenStringLiterals),logHttpError,refreshTokenOnce/ui— the full 67-component shadcn/Radix UI catalog/next—proxyTo/internalUrlroute-handler passthrough, plus the 5 components that rendernext/image(kept out of/uiso that subpath has nonextpeer)/http— new dependency-injectedcreateBareHttp/createAxiosClient/createApolloClient/createQueryClientfactories, replacing the two apps' hand-rolled singleton clients that each read from a different app-specific auth store. Both HTTP factories share one 401-refresh mutex.Byte-identical code was copied verbatim (import paths rewritten from
@/shared/...to the new package layout); the HTTP client factories are the one deliberate redesign, documented in the README.gardenia-webandnextjs-templateare not migrated to consume this package in this PR — that's a follow-up, repo by repo.Test plan
pnpm lint:check— cleanpnpm build—tsc+tsc-alias; all 4 entry points (dist/index.js,dist/entrypoints/{ui,next,http}.js) emit with.d.tscompanionspnpm test:cov— 442 tests across 83 files passing, coverage ≥80% on statements/branches/functions/lines'use client'directives survive the per-filetscbuild unmodifiedGenerated by Claude Code